package com.twu.biblioteca;


public class UserAccount {
    private boolean loggedIn;
    private String password;
    private String name;
    private String email;
    private String phone;

    public UserAccount(String password, String name, String email, String phone){
        loggedIn = false;
        this.password = password;
        this.name = name;
        this.email = email;
        this.phone = phone;
    }

    public void login() {
        loggedIn = true;

    }

    public boolean isLoggedIn() {
        return loggedIn;
    }

    public void logout() {
        loggedIn = false;
    }

    public boolean checkPassword(String password) {
        return this.password.equals(password);
    }

    public String displayInfo() {
       return "Name: " + name + ", Email: " + email + ", Phone Number: " + phone;

    }
}
